Integrand size = 40, antiderivative size = 117 \[ \int \frac {\left (B \cos (c+d x)+C \cos ^2(c+d x)\right ) \sec ^2(c+d x)}{(a+a \cos (c+d x))^3} \, dx=\frac {B \text {arctanh}(\sin (c+d x))}{a^3 d}-\frac {(B-C) \sin (c+d x)}{5 d (a+a \cos (c+d x))^3}-\frac {(7 B-2 C) \sin (c+d x)}{15 a d (a+a \cos (c+d x))^2}-\frac {2 (11 B-C) \sin (c+d x)}{15 d \left (a^3+a^3 \cos (c+d x)\right )} \]
B*arctanh(sin(d*x+c))/a^3/d-1/5*(B-C)*sin(d*x+c)/d/(a+a*cos(d*x+c))^3-1/15 *(7*B-2*C)*sin(d*x+c)/a/d/(a+a*cos(d*x+c))^2-2/15*(11*B-C)*sin(d*x+c)/d/(a ^3+a^3*cos(d*x+c))
Time = 1.45 (sec) , antiderivative size = 197, normalized size of antiderivative = 1.68 \[ \int \frac {\left (B \cos (c+d x)+C \cos ^2(c+d x)\right ) \sec ^2(c+d x)}{(a+a \cos (c+d x))^3} \, dx=\frac {-240 B \cos ^6\left (\frac {1}{2} (c+d x)\right ) \left (\log \left (\cos \left (\frac {1}{2} (c+d x)\right )-\sin \left (\frac {1}{2} (c+d x)\right )\right )-\log \left (\cos \left (\frac {1}{2} (c+d x)\right )+\sin \left (\frac {1}{2} (c+d x)\right )\right )\right )+\cos \left (\frac {1}{2} (c+d x)\right ) \sec \left (\frac {c}{2}\right ) \left (-5 (29 B-4 C) \sin \left (\frac {d x}{2}\right )+75 B \sin \left (c+\frac {d x}{2}\right )-95 B \sin \left (c+\frac {3 d x}{2}\right )+10 C \sin \left (c+\frac {3 d x}{2}\right )+15 B \sin \left (2 c+\frac {3 d x}{2}\right )-22 B \sin \left (2 c+\frac {5 d x}{2}\right )+2 C \sin \left (2 c+\frac {5 d x}{2}\right )\right )}{30 a^3 d (1+\cos (c+d x))^3} \]
(-240*B*Cos[(c + d*x)/2]^6*(Log[Cos[(c + d*x)/2] - Sin[(c + d*x)/2]] - Log [Cos[(c + d*x)/2] + Sin[(c + d*x)/2]]) + Cos[(c + d*x)/2]*Sec[c/2]*(-5*(29 *B - 4*C)*Sin[(d*x)/2] + 75*B*Sin[c + (d*x)/2] - 95*B*Sin[c + (3*d*x)/2] + 10*C*Sin[c + (3*d*x)/2] + 15*B*Sin[2*c + (3*d*x)/2] - 22*B*Sin[2*c + (5*d *x)/2] + 2*C*Sin[2*c + (5*d*x)/2]))/(30*a^3*d*(1 + Cos[c + d*x])^3)
Time = 0.89 (sec) , antiderivative size = 127, normalized size of antiderivative = 1.09, number of steps used = 11, number of rules used = 11, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.275, Rules used = {3042, 3508, 3042, 3457, 3042, 3457, 3042, 3457, 27, 3042, 4257}
Below are the steps used by Rubi to obtain the solution. The rule number used for the transformation is given above next to the arrow. The rules definitions used are listed below.
\(\displaystyle \int \frac {\sec ^2(c+d x) \left (B \cos (c+d x)+C \cos ^2(c+d x)\right )}{(a \cos (c+d x)+a)^3} \, dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \int \frac {B \sin \left (c+d x+\frac {\pi }{2}\right )+C \sin \left (c+d x+\frac {\pi }{2}\right )^2}{\sin \left (c+d x+\frac {\pi }{2}\right )^2 \left (a \sin \left (c+d x+\frac {\pi }{2}\right )+a\right )^3}dx\) |
\(\Big \downarrow \) 3508 |
\(\displaystyle \int \frac {\sec (c+d x) (B+C \cos (c+d x))}{(a \cos (c+d x)+a)^3}dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \int \frac {B+C \sin \left (c+d x+\frac {\pi }{2}\right )}{\sin \left (c+d x+\frac {\pi }{2}\right ) \left (a \sin \left (c+d x+\frac {\pi }{2}\right )+a\right )^3}dx\) |
\(\Big \downarrow \) 3457 |
\(\displaystyle \frac {\int \frac {(5 a B-2 a (B-C) \cos (c+d x)) \sec (c+d x)}{(\cos (c+d x) a+a)^2}dx}{5 a^2}-\frac {(B-C) \sin (c+d x)}{5 d (a \cos (c+d x)+a)^3}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \frac {\int \frac {5 a B-2 a (B-C) \sin \left (c+d x+\frac {\pi }{2}\right )}{\sin \left (c+d x+\frac {\pi }{2}\right ) \left (\sin \left (c+d x+\frac {\pi }{2}\right ) a+a\right )^2}dx}{5 a^2}-\frac {(B-C) \sin (c+d x)}{5 d (a \cos (c+d x)+a)^3}\) |
\(\Big \downarrow \) 3457 |
\(\displaystyle \frac {\frac {\int \frac {\left (15 a^2 B-a^2 (7 B-2 C) \cos (c+d x)\right ) \sec (c+d x)}{\cos (c+d x) a+a}dx}{3 a^2}-\frac {a (7 B-2 C) \sin (c+d x)}{3 d (a \cos (c+d x)+a)^2}}{5 a^2}-\frac {(B-C) \sin (c+d x)}{5 d (a \cos (c+d x)+a)^3}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \frac {\frac {\int \frac {15 a^2 B-a^2 (7 B-2 C) \sin \left (c+d x+\frac {\pi }{2}\right )}{\sin \left (c+d x+\frac {\pi }{2}\right ) \left (\sin \left (c+d x+\frac {\pi }{2}\right ) a+a\right )}dx}{3 a^2}-\frac {a (7 B-2 C) \sin (c+d x)}{3 d (a \cos (c+d x)+a)^2}}{5 a^2}-\frac {(B-C) \sin (c+d x)}{5 d (a \cos (c+d x)+a)^3}\) |
\(\Big \downarrow \) 3457 |
\(\displaystyle \frac {\frac {\frac {\int 15 a^3 B \sec (c+d x)dx}{a^2}-\frac {2 a^2 (11 B-C) \sin (c+d x)}{d (a \cos (c+d x)+a)}}{3 a^2}-\frac {a (7 B-2 C) \sin (c+d x)}{3 d (a \cos (c+d x)+a)^2}}{5 a^2}-\frac {(B-C) \sin (c+d x)}{5 d (a \cos (c+d x)+a)^3}\) |
\(\Big \downarrow \) 27 |
\(\displaystyle \frac {\frac {15 a B \int \sec (c+d x)dx-\frac {2 a^2 (11 B-C) \sin (c+d x)}{d (a \cos (c+d x)+a)}}{3 a^2}-\frac {a (7 B-2 C) \sin (c+d x)}{3 d (a \cos (c+d x)+a)^2}}{5 a^2}-\frac {(B-C) \sin (c+d x)}{5 d (a \cos (c+d x)+a)^3}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \frac {\frac {15 a B \int \csc \left (c+d x+\frac {\pi }{2}\right )dx-\frac {2 a^2 (11 B-C) \sin (c+d x)}{d (a \cos (c+d x)+a)}}{3 a^2}-\frac {a (7 B-2 C) \sin (c+d x)}{3 d (a \cos (c+d x)+a)^2}}{5 a^2}-\frac {(B-C) \sin (c+d x)}{5 d (a \cos (c+d x)+a)^3}\) |
\(\Big \downarrow \) 4257 |
\(\displaystyle \frac {\frac {\frac {15 a B \text {arctanh}(\sin (c+d x))}{d}-\frac {2 a^2 (11 B-C) \sin (c+d x)}{d (a \cos (c+d x)+a)}}{3 a^2}-\frac {a (7 B-2 C) \sin (c+d x)}{3 d (a \cos (c+d x)+a)^2}}{5 a^2}-\frac {(B-C) \sin (c+d x)}{5 d (a \cos (c+d x)+a)^3}\) |
-1/5*((B - C)*Sin[c + d*x])/(d*(a + a*Cos[c + d*x])^3) + (-1/3*(a*(7*B - 2 *C)*Sin[c + d*x])/(d*(a + a*Cos[c + d*x])^2) + ((15*a*B*ArcTanh[Sin[c + d* x]])/d - (2*a^2*(11*B - C)*Sin[c + d*x])/(d*(a + a*Cos[c + d*x])))/(3*a^2) )/(5*a^2)
3.3.74.3.1 Defintions of rubi rules used
Int[(a_)*(Fx_), x_Symbol] :> Simp[a Int[Fx, x], x] /; FreeQ[a, x] && !Ma tchQ[Fx, (b_)*(Gx_) /; FreeQ[b, x]]
Int[((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)])^(m_)*((A_.) + (B_.)*sin[(e_.) + (f_.)*(x_)])*((c_.) + (d_.)*sin[(e_.) + (f_.)*(x_)])^(n_), x_Symbol] :> Sim p[b*(A*b - a*B)*Cos[e + f*x]*(a + b*Sin[e + f*x])^m*((c + d*Sin[e + f*x])^( n + 1)/(a*f*(2*m + 1)*(b*c - a*d))), x] + Simp[1/(a*(2*m + 1)*(b*c - a*d)) Int[(a + b*Sin[e + f*x])^(m + 1)*(c + d*Sin[e + f*x])^n*Simp[B*(a*c*m + b *d*(n + 1)) + A*(b*c*(m + 1) - a*d*(2*m + n + 2)) + d*(A*b - a*B)*(m + n + 2)*Sin[e + f*x], x], x], x] /; FreeQ[{a, b, c, d, e, f, A, B, n}, x] && NeQ [b*c - a*d, 0] && EqQ[a^2 - b^2, 0] && NeQ[c^2 - d^2, 0] && LtQ[m, -2^(-1)] && !GtQ[n, 0] && IntegerQ[2*m] && (IntegerQ[2*n] || EqQ[c, 0])
Int[((a_.) + (b_.)*sin[(e_.) + (f_.)*(x_)])^(m_.)*((c_.) + (d_.)*sin[(e_.) + (f_.)*(x_)])^(n_.)*((A_.) + (B_.)*sin[(e_.) + (f_.)*(x_)] + (C_.)*sin[(e_ .) + (f_.)*(x_)]^2), x_Symbol] :> Simp[1/b^2 Int[(a + b*Sin[e + f*x])^(m + 1)*(c + d*Sin[e + f*x])^n*(b*B - a*C + b*C*Sin[e + f*x]), x], x] /; FreeQ [{a, b, c, d, e, f, A, B, C, m, n}, x] && NeQ[b*c - a*d, 0] && EqQ[A*b^2 - a*b*B + a^2*C, 0]
Int[csc[(c_.) + (d_.)*(x_)], x_Symbol] :> Simp[-ArcTanh[Cos[c + d*x]]/d, x] /; FreeQ[{c, d}, x]
Time = 2.78 (sec) , antiderivative size = 95, normalized size of antiderivative = 0.81
method | result | size |
parallelrisch | \(\frac {-20 B \ln \left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )-1\right )+20 B \ln \left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )+1\right )-\tan \left (\frac {d x}{2}+\frac {c}{2}\right ) \left (\left (B -C \right ) \left (\tan ^{4}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )+\frac {10 \left (2 B -C \right ) \left (\tan ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{3}+35 B -5 C \right )}{20 a^{3} d}\) | \(95\) |
derivativedivides | \(\frac {-4 B \ln \left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )-1\right )-7 B \tan \left (\frac {d x}{2}+\frac {c}{2}\right )+\tan \left (\frac {d x}{2}+\frac {c}{2}\right ) C -\frac {4 \left (\tan ^{3}\left (\frac {d x}{2}+\frac {c}{2}\right )\right ) B}{3}+\frac {2 \left (\tan ^{3}\left (\frac {d x}{2}+\frac {c}{2}\right )\right ) C}{3}+4 B \ln \left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )+1\right )-\frac {\left (\tan ^{5}\left (\frac {d x}{2}+\frac {c}{2}\right )\right ) B}{5}+\frac {\left (\tan ^{5}\left (\frac {d x}{2}+\frac {c}{2}\right )\right ) C}{5}}{4 d \,a^{3}}\) | \(119\) |
default | \(\frac {-4 B \ln \left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )-1\right )-7 B \tan \left (\frac {d x}{2}+\frac {c}{2}\right )+\tan \left (\frac {d x}{2}+\frac {c}{2}\right ) C -\frac {4 \left (\tan ^{3}\left (\frac {d x}{2}+\frac {c}{2}\right )\right ) B}{3}+\frac {2 \left (\tan ^{3}\left (\frac {d x}{2}+\frac {c}{2}\right )\right ) C}{3}+4 B \ln \left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )+1\right )-\frac {\left (\tan ^{5}\left (\frac {d x}{2}+\frac {c}{2}\right )\right ) B}{5}+\frac {\left (\tan ^{5}\left (\frac {d x}{2}+\frac {c}{2}\right )\right ) C}{5}}{4 d \,a^{3}}\) | \(119\) |
risch | \(-\frac {2 i \left (15 B \,{\mathrm e}^{4 i \left (d x +c \right )}+75 B \,{\mathrm e}^{3 i \left (d x +c \right )}+145 B \,{\mathrm e}^{2 i \left (d x +c \right )}-20 C \,{\mathrm e}^{2 i \left (d x +c \right )}+95 B \,{\mathrm e}^{i \left (d x +c \right )}-10 C \,{\mathrm e}^{i \left (d x +c \right )}+22 B -2 C \right )}{15 d \,a^{3} \left ({\mathrm e}^{i \left (d x +c \right )}+1\right )^{5}}+\frac {B \ln \left ({\mathrm e}^{i \left (d x +c \right )}+i\right )}{a^{3} d}-\frac {B \ln \left ({\mathrm e}^{i \left (d x +c \right )}-i\right )}{a^{3} d}\) | \(146\) |
norman | \(\frac {-\frac {\left (B -C \right ) \left (\tan ^{11}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{20 a d}+\frac {5 \left (5 B -C \right ) \left (\tan ^{3}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{12 a d}+\frac {\left (7 B -C \right ) \tan \left (\frac {d x}{2}+\frac {c}{2}\right )}{4 a d}-\frac {\left (23 B -13 C \right ) \left (\tan ^{9}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{60 a d}-\frac {\left (41 B -C \right ) \left (\tan ^{5}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{30 a d}-\frac {\left (61 B -11 C \right ) \left (\tan ^{7}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{30 a d}}{\left (1+\tan ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )^{2} \left (\tan ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )-1\right ) a^{2}}+\frac {B \ln \left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )+1\right )}{a^{3} d}-\frac {B \ln \left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )-1\right )}{a^{3} d}\) | \(230\) |
1/20*(-20*B*ln(tan(1/2*d*x+1/2*c)-1)+20*B*ln(tan(1/2*d*x+1/2*c)+1)-tan(1/2 *d*x+1/2*c)*((B-C)*tan(1/2*d*x+1/2*c)^4+10/3*(2*B-C)*tan(1/2*d*x+1/2*c)^2+ 35*B-5*C))/a^3/d
Time = 0.26 (sec) , antiderivative size = 185, normalized size of antiderivative = 1.58 \[ \int \frac {\left (B \cos (c+d x)+C \cos ^2(c+d x)\right ) \sec ^2(c+d x)}{(a+a \cos (c+d x))^3} \, dx=\frac {15 \, {\left (B \cos \left (d x + c\right )^{3} + 3 \, B \cos \left (d x + c\right )^{2} + 3 \, B \cos \left (d x + c\right ) + B\right )} \log \left (\sin \left (d x + c\right ) + 1\right ) - 15 \, {\left (B \cos \left (d x + c\right )^{3} + 3 \, B \cos \left (d x + c\right )^{2} + 3 \, B \cos \left (d x + c\right ) + B\right )} \log \left (-\sin \left (d x + c\right ) + 1\right ) - 2 \, {\left (2 \, {\left (11 \, B - C\right )} \cos \left (d x + c\right )^{2} + 3 \, {\left (17 \, B - 2 \, C\right )} \cos \left (d x + c\right ) + 32 \, B - 7 \, C\right )} \sin \left (d x + c\right )}{30 \, {\left (a^{3} d \cos \left (d x + c\right )^{3} + 3 \, a^{3} d \cos \left (d x + c\right )^{2} + 3 \, a^{3} d \cos \left (d x + c\right ) + a^{3} d\right )}} \]
integrate((B*cos(d*x+c)+C*cos(d*x+c)^2)*sec(d*x+c)^2/(a+a*cos(d*x+c))^3,x, algorithm="fricas")
1/30*(15*(B*cos(d*x + c)^3 + 3*B*cos(d*x + c)^2 + 3*B*cos(d*x + c) + B)*lo g(sin(d*x + c) + 1) - 15*(B*cos(d*x + c)^3 + 3*B*cos(d*x + c)^2 + 3*B*cos( d*x + c) + B)*log(-sin(d*x + c) + 1) - 2*(2*(11*B - C)*cos(d*x + c)^2 + 3* (17*B - 2*C)*cos(d*x + c) + 32*B - 7*C)*sin(d*x + c))/(a^3*d*cos(d*x + c)^ 3 + 3*a^3*d*cos(d*x + c)^2 + 3*a^3*d*cos(d*x + c) + a^3*d)
\[ \int \frac {\left (B \cos (c+d x)+C \cos ^2(c+d x)\right ) \sec ^2(c+d x)}{(a+a \cos (c+d x))^3} \, dx=\frac {\int \frac {B \cos {\left (c + d x \right )} \sec ^{2}{\left (c + d x \right )}}{\cos ^{3}{\left (c + d x \right )} + 3 \cos ^{2}{\left (c + d x \right )} + 3 \cos {\left (c + d x \right )} + 1}\, dx + \int \frac {C \cos ^{2}{\left (c + d x \right )} \sec ^{2}{\left (c + d x \right )}}{\cos ^{3}{\left (c + d x \right )} + 3 \cos ^{2}{\left (c + d x \right )} + 3 \cos {\left (c + d x \right )} + 1}\, dx}{a^{3}} \]
(Integral(B*cos(c + d*x)*sec(c + d*x)**2/(cos(c + d*x)**3 + 3*cos(c + d*x) **2 + 3*cos(c + d*x) + 1), x) + Integral(C*cos(c + d*x)**2*sec(c + d*x)**2 /(cos(c + d*x)**3 + 3*cos(c + d*x)**2 + 3*cos(c + d*x) + 1), x))/a**3
Time = 0.21 (sec) , antiderivative size = 187, normalized size of antiderivative = 1.60 \[ \int \frac {\left (B \cos (c+d x)+C \cos ^2(c+d x)\right ) \sec ^2(c+d x)}{(a+a \cos (c+d x))^3} \, dx=-\frac {B {\left (\frac {\frac {105 \, \sin \left (d x + c\right )}{\cos \left (d x + c\right ) + 1} + \frac {20 \, \sin \left (d x + c\right )^{3}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{3}} + \frac {3 \, \sin \left (d x + c\right )^{5}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{5}}}{a^{3}} - \frac {60 \, \log \left (\frac {\sin \left (d x + c\right )}{\cos \left (d x + c\right ) + 1} + 1\right )}{a^{3}} + \frac {60 \, \log \left (\frac {\sin \left (d x + c\right )}{\cos \left (d x + c\right ) + 1} - 1\right )}{a^{3}}\right )} - \frac {C {\left (\frac {15 \, \sin \left (d x + c\right )}{\cos \left (d x + c\right ) + 1} + \frac {10 \, \sin \left (d x + c\right )^{3}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{3}} + \frac {3 \, \sin \left (d x + c\right )^{5}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{5}}\right )}}{a^{3}}}{60 \, d} \]
integrate((B*cos(d*x+c)+C*cos(d*x+c)^2)*sec(d*x+c)^2/(a+a*cos(d*x+c))^3,x, algorithm="maxima")
-1/60*(B*((105*sin(d*x + c)/(cos(d*x + c) + 1) + 20*sin(d*x + c)^3/(cos(d* x + c) + 1)^3 + 3*sin(d*x + c)^5/(cos(d*x + c) + 1)^5)/a^3 - 60*log(sin(d* x + c)/(cos(d*x + c) + 1) + 1)/a^3 + 60*log(sin(d*x + c)/(cos(d*x + c) + 1 ) - 1)/a^3) - C*(15*sin(d*x + c)/(cos(d*x + c) + 1) + 10*sin(d*x + c)^3/(c os(d*x + c) + 1)^3 + 3*sin(d*x + c)^5/(cos(d*x + c) + 1)^5)/a^3)/d
Time = 0.34 (sec) , antiderivative size = 148, normalized size of antiderivative = 1.26 \[ \int \frac {\left (B \cos (c+d x)+C \cos ^2(c+d x)\right ) \sec ^2(c+d x)}{(a+a \cos (c+d x))^3} \, dx=\frac {\frac {60 \, B \log \left ({\left | \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right ) + 1 \right |}\right )}{a^{3}} - \frac {60 \, B \log \left ({\left | \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right ) - 1 \right |}\right )}{a^{3}} - \frac {3 \, B a^{12} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{5} - 3 \, C a^{12} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{5} + 20 \, B a^{12} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{3} - 10 \, C a^{12} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{3} + 105 \, B a^{12} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right ) - 15 \, C a^{12} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )}{a^{15}}}{60 \, d} \]
1/60*(60*B*log(abs(tan(1/2*d*x + 1/2*c) + 1))/a^3 - 60*B*log(abs(tan(1/2*d *x + 1/2*c) - 1))/a^3 - (3*B*a^12*tan(1/2*d*x + 1/2*c)^5 - 3*C*a^12*tan(1/ 2*d*x + 1/2*c)^5 + 20*B*a^12*tan(1/2*d*x + 1/2*c)^3 - 10*C*a^12*tan(1/2*d* x + 1/2*c)^3 + 105*B*a^12*tan(1/2*d*x + 1/2*c) - 15*C*a^12*tan(1/2*d*x + 1 /2*c))/a^15)/d
Time = 1.42 (sec) , antiderivative size = 130, normalized size of antiderivative = 1.11 \[ \int \frac {\left (B \cos (c+d x)+C \cos ^2(c+d x)\right ) \sec ^2(c+d x)}{(a+a \cos (c+d x))^3} \, dx=\frac {2\,B\,\mathrm {atanh}\left (\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )\right )}{a^3\,d}-\frac {\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )\,\left (\frac {B-C}{4\,a^3}+\frac {3\,B+C}{4\,a^3}+\frac {3\,B-C}{4\,a^3}\right )}{d}-\frac {{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^5\,\left (B-C\right )}{20\,a^3\,d}-\frac {{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^3\,\left (\frac {B-C}{12\,a^3}+\frac {3\,B-C}{12\,a^3}\right )}{d} \]